var $debates = $('#debates');
var $orderFilterInput = $('.order_filter');

$debates.html('<%= j(render partial: "debates").strip.html_safe %>');
$orderFilterInput.val('<%= order %>');

$debates[0].innerHTML = $debates[0].innerHTML.replace('data-open="false"', 'data-open="true"');
document.dispatchEvent(new CustomEvent("ajax:loaded", { detail: $debates[0] }));
